<?php
$loader->requireOnce('includes/inPatientCore/IInPatientQueue.class.php');
$loader->requireOnce('includes/inPatientCore/InPatientCoreErrorCode.class.php');
$loader->requireOnce('includes/inPatientCore/InPatientCoreException.class.php');
$loader->requireOnce('includes/EmerDoctorQueue.class.php');
/**
 * Factory for building emergency inpatione queues.
 * @package module.dept_emer.includes
 * @author hdviet
 * @version $Id$
 * @copyright 2009 LHV Company
 */
class EmerQueueFactory {
	
	const DOCTOR = 'doctor';
	/**
	 * Build queue object
	 * @param $type type of queue <br>
	 * DOCTOR
	 * @return queue object
	 * @throw InpatientCoreException if type is not supported.
	 */
	public static function getQueue($type) {
		switch ($type) {
			case self::DOCTOR:				
				return new EmerDoctorQueue();			
			default:
				throw new InpatientCoreException("Queue $type is not supported");
		}
		
	}
}
?>